﻿using Stardust.Common.Enum;
using Stardust.Common.Model;
using Stardust.ConfigCenterWeb.Code.Entities;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Stardust.ConfigCenterWeb.Code.Repositories
{
    public interface IServerNodeRepository
    {
        List<ServerNode> SearchList(string serviceName, string address, string version, ServerNodeStatus? status);

        long Add(ServerNode m);

        long Update(ServerNode m);

        long Delete(long nodeId);

        int Heartbeat(long nodeId);

        int Logout(long nodeId);

        ServerNode GetOne(long nodeId);

        ServerNode GetNodeByName(string serviceName, string address);

        List<ServerNode> GetCheckAliveNodes();

        List<ServerNode> GetCheckRegisterNodes();


    }
}
